<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
    <script src="lib/axios.min.js"></script>
</head>
<body>
    <input type="button" value="点击发送请求" onclick="get()">
    <div style="border:1px solid red;">
        用户名：<input id="username" type="text">
        密码：<input id="password" type="password" id="password">
        身份证号：<input type="text" id="identify">
        <button onclick="get_user()">提交</button>
    </div>
</body>
<script>
    function get(){
      axios.get("/get_usename").then(function(res){
      console.log(res)
    })
    }
    function get_user(){
    var username=document.getElementById("username")
    var password=document.getElementById("password")
    var identify=document.getElementById("identify")
    axios.post("/register_use",{
        username:username,
        password:password,
        identify:identify
    }).then(function(result){
        console.log(result.data)
        if(result.data.status==10000){
            alert(ok)
        }
        else{
            alert(result.data.msg)
        }
    })
    }
</script>
</html>